
<script language="javascript">
function applyjobs()
{
	document.applyjob.method="post";
	document.applyjob.action="index.php?view=apply_job";
	document.applyjob.submit();
}

</script>
   
  
    <div class="contentwarp">
    
      <!-- Begin contentwarpMiddle -->
      <div class="contentwarpMiddle">
         <div id="content" style="background-color:#FFF;float:left;width:900px; padding-left:20px; border:0px solid #CCC;">  
      <h1 >Find Jobs</h1>
      <div>
        <h2>Apply Jobs</h2>
       <form name="applyjob" method="post"> 
        <div class="contentArea1">
          <div class="browse-capital clearfix">
            <ul>
              <li>
              	<?php 
	if($_GET['id']!="")
	{
	
	// echo '<a href="index.php?page=view_job&id='.$tech['id'].'" class="job">'.$tech['job_nature'].'<br></a>';
     $sql="select * from job_post  where cat_id='".$_GET['id']."' and   active_status='1'";
	$sql=mysql_query($sql);
	$count=mysql_num_rows($sql);
	while($tech=mysql_fetch_array($sql))
	 {?><br />
        <div style="height:180px; width:700px; background-color:#F8F8F8; margin-left:15px;" class="borders">
        <table width="100%" height="60%" border="0">
        <tr>
        	<td style="color:#098BBB; font-weight:bold; font-size:14px;" colspan="2">
			<!--<input type="checkbox" name="applycheck[]" value="<?php //echo $tech[id] ?>" />-->
			<?php echo $tech[job_nature]; 	
				
			?>
            </td>
        </tr>
        <tr>
        <td style="color:#A7A7A7" colspan="2" >
        	<?php  echo substr($tech[job_desc],0,300).'.....'; ?>
            
            
        </td>
        </tr> 
         <tr>
        <td style="color:#A7A7A7" >
            Basic $<b><?php  echo $tech[salary].'&nbsp;'.$tech[salary_type]; ?></b>
            <br /> Posted by <b><?php  echo $tech[company_name]; ?>
      </b>
      <br /> Closing Date <b><?php
	  $dateArray=explode('-',$tech[closing_date]);
	echo date('M j, Y', mktime(0, 0, 0, $dateArray[1], $dateArray[2], $dateArray[0])); ?>
      </b>
      </td><td align="right">
         <div style="margin-top:10px;"><a href="index.php?page=jobs&view=apply_job&post_id=<?php echo $tech[id] ?>"><img src="images/applyjob.png" onclick="return applyjobs();"  /></a> &nbsp;</div>
       </td></tr>
        </table>
        </div> 
		
		 
	 <?php }
	}
	
    if(($_GET['jid']!="") or ($_GET['s_id']!="") )
	{
	
	
	if($_GET['jid']!=""){
	$sql="select * from job_post  where zone_id='".$_GET['jid']."' and   active_status='1'";
	}
	else
	{
		 $sql="select * from job_post  where  job_nature like '%".$_GET['s_id']."%'
	 or job_desc like '%".$_GET['s_id']."%'
	 or zone_id ='".$_GET['area_id']."' or 
	 sub_cat_id ='".$_GET['list_job']."'
	 
	 and   active_status='1'";
	}
	$d=0;
	$sql=mysql_query($sql);
	$count=mysql_num_rows($sql);
	while($tech=mysql_fetch_array($sql))
	 {$d++;
	$bg = ($d%2==0)? "#E4E4E4" : "#E4EDF5";?><br />
		<div class="borders" style="height:170px; width:700px; background-color:<?php echo $bg;?>; margin-left:15px; border:1px solid <?php echo $bg;?>;" >
        <table width="100%" height="60%" border="0">
        <tr>
        	<td style="color:#098BBB; font-weight:bold; font-size:14px;" colspan="2">
		<!--	<input type="checkbox" name="applycheck[]" value="<?php echo $tech[id] ?>" />-->
			<?php echo $tech[job_nature]; 	
				
			?>
            </td>
        </tr>
        <tr>
        <td colspan="2" class="font12">
        	<?php  echo substr($tech[job_desc],0,300).'.....'; ?>
          
            
        </td>
        </tr> 
         <tr>
        <td class="font12">
            Basic $<b><?php  echo $tech[salary].'&nbsp;'.$tech[salary_type]; ?></b>
            <br /> Posted by <b><?php  echo $tech[company_name]; ?>
      </b>
      <br /> Closing Date <b><?php
	  $dateArray=explode('-',$tech[closing_date]);
	echo date('M j, Y', mktime(0, 0, 0, $dateArray[1], $dateArray[2], $dateArray[0])); ?>
      </b>
      </td><td align="right">
         <div style="margin-top:10px;"><a href="index.php?page=jobs&view=apply_job&post_id=<?php echo $tech[id] ?>"><img src="images/applyjob.png" onclick="return applyjobs();"  /></a></div>
       </td></tr>
        </table>
        </div>
        
	<?php 
	} }
	if($_GET['a_id']!="")
	{?>
		<div style="min-height:150px; width:700px; background-color:#F8F8F8; border:#ccc solid 1px; margin-left:15px;">
        <?php 
			$sql="select jp.job_nature,z.id from zone z inner join job_post jp on z.id=jp.zone_id where  
			z.zone_name like'%".$_GET['a_id']."%' and jp.active_status='1'";
			$sql=mysql_query($sql);
			while($tech=mysql_fetch_array($sql))
	 		{
			 echo '<span style="margin-left:10px;"><a href="index.php?page=jobs&view=view_job&jid='.$tech[id].'">'.$tech[job_nature].'</a></span><br>';     
			 }  
			?>
        </div>
<?php	}
    ?>
  
              </li>
            </ul>
          
          </div>
          
        </div>
        
      
       <div align="center">
           <!-- <input type="image" src="images/apply-selected-job.png" />-->
            <input type="hidden" name="process" id="process" value=""/>
            <input type="hidden" name="module" id="module" value="applyjob"/>
            </div></form>
      
      
      
      <!-- Define wide ad unit. "google_afs_request_done" function populates ads.-->
    </div>
      </div>
      <!-- End contentwarpMiddle -->
      
        
      
      <!-- End contentwarp -->
      <div style="clear:both;"></div>
    </div> <?php //include("includes/right_content.php");?>
    <!-- End mainWarpArea -->
    <div style="clear:both;"></div>

